<%= form_for @enter,
     :url => create_enter_order_url,
     :remote => true,
     :method => :post do |f|
 %>
<h6><b>新增-入库登记</b></h6>
<%= f.hidden_field :order_item_id %>
<dl>
  <dt>
    订做记录
  </dt>
  <dd>
    <%= f.select :order_made_id, @order_mades.collect {|order_made| [ "\"#{order_made.order_made_on}\"向『#{order_made.factory_name}』订做【#{order_made.order_made_count}】件", order_made.id ] }, {},:id => "order_item_#{@enter.order_item_id}_order_made_id" %>
  </dd>
</dl>
<dl>
  <dt>
    工厂名
  </dt>
  <dd>
    <%= f.text_field :factory_name %>
  </dd>
</dl>
<dl>
  <dt>
    仓库名
  </dt>
  <dd>
    <%= f.text_field :warehouse_name %>
  </dd>
</dl>
<dl>
  <dt>
    包装号
  </dt>
  <dd>
    <%= f.text_field :package_codes %>
  </dd>
</dl>
<dl>
  <dt>
    数量
  </dt>
  <dd>
    <%= f.text_field :entered_count %>
  </dd>
</dl>
<dl>
  <dt>
    入库时间
  </dt>
  <dd>
    <%= f.text_field :entered_on, :class => :date %>
    <script>
      $('#enter_entered_on').datepicker({
        showButtonPanel: true
      });
    </script>
  </dd>
</dl>
<dl>
  <dt>
    备注
  </dt>
  <dd>
    <%= f.text_area :remark, :rows => 5%>
  </dd>
</dl>
<dl>
  <dd class="form_tool">
    <%= f.submit '保存' %>
    <%= link_to '返回', new_feed_order_url(@enter.order_item),:remote => true, :method => :get, :id => "new_enter_btn#{@enter.order_item.id}", :class => 'button' %>
  </dd>
</dl>
<div class="clear"></div>
<%end%>
